package com.ctshk.rpc.train.req;

import com.ctshk.common.model.PageReq;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.time.LocalDate;

/**
 * <p>
 * 火车票预订查询req
 * </p>
 *
 * @author 彭柳霖
 * @since 2021-02-09
 */
@Data
@ApiModel(value="ReservationBusPageReq对象", description="火车票预订查询req")
public class ReservationTrainPageReq extends PageReq  implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "铁路公司名称")
    //@NotNull(message = "请选择火车票类型")
    private String railwayCorporationName;

    @ApiModelProperty(value = "出发城市名称")
    private String departureCityName;

    @ApiModelProperty(value = "到达城市名称")
    private String arriveCityName;

    @ApiModelProperty(value = "上车站名称")
    @NotNull(message = "请选择出发站")
    private String boardingStationName;

    @ApiModelProperty(value = "下车站点名称")
    @NotNull(message = "请选择到达站")
    private String alightingStationName;

    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @NotNull(message = "请选择出发日期")
    @ApiModelProperty(value = "出发日期")
    private LocalDate queryDate;

    @ApiModelProperty(value = "出发日期+1天")
    private LocalDate tomorrowQueryDate;

    @ApiModelProperty(value = "旅客类型")
    private Integer passengerType;

    @ApiModelProperty(value = "座位库存数")
    private Integer inventory = 0;

    @ApiModelProperty("成人数量")
    private Integer passengerAdultNum = 0;

    @ApiModelProperty("小童数量")
    private Integer passengerChildrenNum = 0;

    @ApiModelProperty("老人数量")
    private Integer passengerOldNum = 0;

    @ApiModelProperty("车次")
    private String trainType;

    @ApiModelProperty("默认值为0, 港铁: 1")
    private Integer railwayTypeCode = 0;
}
